Welcome to MacMarlais. This is a port of the UN*X program Marlais (version 0.5) to the Macintosh. MacMarlais provides a nice, multiple window, text editing environment for creating Marlais programs. Marlais is a language not unlike Dylan™, from Apple Computer.
Version 0.5 now implements a subset of the infix syntax. See the Dylan interim reference manual for a full description of this syntax.
Installation
------------
MacMarlais uses Apple's thread manager which is available from ftp.apple.com. In the future this may be included with MacMarlais. The thread manager is used to run the interpreter in a separate thread from the user interface. This makes it easier to interrupt the interpreter and keeps the code nicely modular.
Limitations
-----------
There seems to be a problem running MacMarlais under 24-bit mode, so you'll have to have a 32-bit capable Macintosh running in 32-bit mode.
Getting Started
---------------
• You can evaluate statements by typing them directly into the "Listener" window, by loading them from a file from the "Marlais" menu, or by selecting text in any window and hitting cmd-E. For example, to print a message, type this into the "Listener" window:
princ("Hello Mr. Thomas!");
and press return. You must end the line with a semi-colon (;) character before Marlais will execute your input. As a convenience, if you hit the enter key instead of return, Marlais will type the semi-colon for you.
• You can hide the "Listener" window and bring it back by choosing "Listener" from the "Marlais" menu, or by hitting cmd-I.
• You can abort the current computation or the current input line by hitting
cmd–period or choosing "Interrupt" from the "Marlais" menu.
• Syntax Switching -- You can use either the new syntax, or the old, by switching the syntax in the Marlais menu Syntax hierarchical menu. When you toggle the syntax, it will act as if you had typed cmd–period so that the interpreter's scanner will be reset, so don't worry about the message that gets printed out.
• Only two Macintosh specific instrinsics have been implemented. These are get-file() and put-file(). get-file() displays the standard get file dialog. If the user cancels the dialog, #f is returned, otherwise the full pathname of the file selected is returned as a string. You can use this path name as an argument to the various file functions available in Marlais. For example:
begin
let file-name = get-file();
if (file-name)
load(file-name); // better be a source file!
end;
end;
put-file() opens the standard put file dialog. This is used to obtain a new file name and location from the user. It has two optional arguments, the first being the suggested file name the user can use, and the second being the prompt string to use. Here's an example:
begin
let new-file-name = put-file("Untitled-1", "Give me a name:");
if (new-file-name)
print(new-file-name);
end;
end;
If the second parameter isn't specified, the default prompt string is "Save as:". If the first parameter isn't specified, the dialog doesn't contain a default name and the user must enter one or hit cancel. Again, if cancel is selected, #f is returned, otherwise the full path name to the file is returned as a string.
Reporting Bugs
--------------
If a bug seems specific to the Macintosh interface, or keyboard input, please
notify the author by sending mail to beard@cs.ucdavis.edu. If you find a language
bug, send me a message, and cc: it to jnw@cis.ufl.edu, who is developing the UN*X version.
For More Information
--------------------
Further Dylan information is available from the following places: